/*
 * AnimalTransportado.java
 *
 * Created on October 12, 2007, 10:46 PM
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package petstore.model;

import javax.persistence.AttributeOverride;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * Entity class AnimalTransportado
 * 
 * @author Tom Hayden
 */
@Entity
@Table(name = "animal_transportado")
@AttributeOverride(name="id", column=@Column(name="cdanimaltransp"))
public class AnimalTransportado extends BusinessObject {

    @Column(name = "vlrunitanimal")
    private Double valorUnitarioAnimal;

    @ManyToOne
    @JoinColumn(name="cdanimal")
    private Animal animal;

    @ManyToOne
    @JoinColumn(name="cditinerario")
    private Itinerario itinerario;
    
    /** Creates a new instance of AnimalTransportado */
    public AnimalTransportado() {
    }

    public Double getValorUnitarioAnimal() {
        return valorUnitarioAnimal;
    }

    public void setValorUnitarioAnimal(Double valorUnitarioAnimal) {
        this.valorUnitarioAnimal = valorUnitarioAnimal;
    }

    public Animal getAnimal() {
        return animal;
    }

    public void setAnimal(Animal animal) {
        this.animal = animal;
    }

    public Itinerario getItinerario() {
        return itinerario;
    }

    public void setItinerario(Itinerario itinerario) {
        this.itinerario = itinerario;
    }
        
}
